package com.coder.oj.system.dto;

import com.coder.oj.common.validate.ValidationGroups;
import io.swagger.annotations.ApiModelProperty;
import lombok.Data;

import javax.validation.constraints.NotBlank;
import javax.validation.constraints.NotEmpty;
import javax.validation.constraints.NotNull;
import java.io.Serializable;

@Data
public class CaseDto implements Serializable {

    @ApiModelProperty("主键id")
    @NotNull(message = "主键id不能为空", groups = {ValidationGroups.Update.class})
    private Long id;

    @ApiModelProperty("题目id")
    @NotNull(message = "题目id不能为空", groups = {ValidationGroups.Insert.class})
    private Long problemId;

    @ApiModelProperty("输入")
    @NotBlank(message = "输入不能为空", groups = {ValidationGroups.Insert.class, ValidationGroups.Update.class})
    private String input;

    @ApiModelProperty("输出")
    @NotBlank(message = "输出不能为空", groups = {ValidationGroups.Insert.class, ValidationGroups.Update.class})
    private String output;

    @ApiModelProperty("状态")
    @NotNull(message = "状态不能为空", groups = {ValidationGroups.Insert.class, ValidationGroups.Update.class})
    private Integer status;
}
